* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: #f5f5f5;
    color: #333;
}

#app {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.header {
    background: #2c3e50;
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h1 {
    font-size: 20px;
    font-weight: 600;
}

.status {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.stopped {
    background: #e74c3c;
}

.dot.running {
    background: #2ecc71;
}

.container {
    display: flex;
    gap: 20px;
    padding: 20px;
    flex: 1;
    overflow: hidden;
}

.panel {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow-y: auto;
}

.panel:first-child {
    width: 350px;
    flex-shrink: 0;
}

.flex-grow {
    flex: 1;
}

h2 {
    font-size: 18px;
    margin-bottom: 20px;
    color: #2c3e50;
}

h3 {
    font-size: 14px;
    margin-bottom: 10px;
    color: #555;
}

.section {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.section:last-child {
    border-bottom: none;
}

.button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background: #3498db;
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: #2980b9;
}

.btn-secondary {
    background: #95a5a6;
    color: white;
}

.btn-secondary:hover:not(:disabled) {
    background: #7f8c8d;
}

.btn-danger {
    background: #e74c3c;
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background: #c0392b;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

.info-item {
    margin-bottom: 15px;
}

.info-item label {
    display: block;
    margin-bottom: 5px;
    font-size: 13px;
    color: #666;
}

.access-urls {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 13px;
    margin-bottom: 8px;
    word-break: break-all;
}

input[type="text"],
input[type="number"] {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

input[type="text"]:focus,
input[type="number"]:focus {
    outline: none;
    border-color: #3498db;
}

.password-control {
    display: flex;
    gap: 8px;
    align-items: center;
}

.password-control input {
    flex: 1;
}

.file-stats {
    margin-top: 15px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
    font-size: 13px;
}

.file-stats div {
    margin-bottom: 5px;
}

.file-stats div:last-child {
    margin-bottom: 0;
}

.file-list {
    max-height: calc(100vh - 400px);
    overflow-y: auto;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state p {
    margin-bottom: 10px;
}

.hint {
    font-size: 12px;
    color: #bbb;
}

.file-item {
    padding: 12px;
    border: 1px solid #eee;
    border-radius: 4px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.file-item:hover {
    background: #f8f9fa;
}

.file-info {
    flex: 1;
}

.file-name {
    font-weight: 500;
    margin-bottom: 5px;
}

.file-meta {
    font-size: 12px;
    color: #666;
}

.file-actions {
    display: flex;
    gap: 8px;
}

.footer {
    background: white;
    border-top: 1px solid #ddd;
    height: 200px;
    display: flex;
    flex-direction: column;
}

.tabs {
    display: flex;
    border-bottom: 1px solid #ddd;
}

.tab {
    padding: 10px 20px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    color: #666;
    transition: all 0.2s;
}

.tab.active {
    color: #3498db;
    border-bottom: 2px solid #3498db;
}

.log-content {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
}

.log-list {
    font-size: 13px;
}

.log-entry {
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
    font-family: monospace;
}

.log-entry:last-child {
    border-bottom: none;
}

.log-time {
    color: #999;
    margin-right: 10px;
}

.log-success {
    color: #2ecc71;
}

.log-error {
    color: #e74c3c;
}

/* 弹窗样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 20px;
    color: #2c3e50;
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.modal-close:hover {
    color: #333;
}

.modal-body {
    padding: 20px;
}

.modal-description {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.6;
}

.filter-section {
    margin-bottom: 25px;
}

.filter-section h3 {
    font-size: 16px;
    margin-bottom: 12px;
    color: #2c3e50;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    display: inline-block;
    padding: 6px 12px;
    background: #e8f4f8;
    color: #2980b9;
    border-radius: 4px;
    font-size: 13px;
    font-family: monospace;
}

.filter-list {
    list-style: none;
    padding: 0;
}

.filter-list li {
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
    color: #555;
    line-height: 1.6;
}

.filter-list li:last-child {
    border-bottom: none;
}

.filter-list code {
    background: #f8f9fa;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: monospace;
    color: #e74c3c;
    font-size: 13px;
}
